package com.koron.plan.web.maintainplan.bean.query;

import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.PositiveOrZero;
import java.util.Date;
import java.util.List;

/**
 * @author twcao
 * @title: MaintainPlanQuery
 * @projectName GDH_EAM_V2
 * @description: 维保计划查询条件
 * @date 2022/4/229:56
 */
@Data
@ApiModel(description = "水司维保计划信息表")
public class MaintainPlanQuery {

    @ApiModelProperty(value = "唯一id")
    private String id;

    @ApiModelProperty("编码,系统自动生成，作为系统数据唯一标识，必须唯一")
    private String code;

    @ApiModelProperty("计划名称")
    @Length(max = 64, message = "计划名称不得超过64个字符")
    @NotBlank(message = "请输入计划名称")
    private String name;

    @ApiModelProperty("设备管理单位ID")
    private String deptManage;

    @ApiModelProperty("设备管理单位名称")
    private String deptManageName;

    @ApiModelProperty("工作地点名称")
    private String address;

    @ApiModelProperty("工作地点id")
    private String addressId;

    @ApiModelProperty("专业")
    private String major;

    @ApiModelProperty("工期数值，如：5天，数值为5")
    @PositiveOrZero(message = "工期只能为正数或0")
    private Integer timeNum;

    @ApiModelProperty("工期单位，如：5天，单位为天")
    private String timePeriod;

    @ApiModelProperty("延迟开始天数")
    @PositiveOrZero(message = "延迟天数只能为正数或0")
    private Double delayDays;

    @ApiModelProperty("工单性质，0，生产工单；1非生产工单")
    private Integer nature;

    @ApiModelProperty("是否定时下达")
    private Integer isTimer;

    @ApiModelProperty("是否需要作业表单")
    private Integer isNeed;

    @ApiModelProperty("是否派工,0，不派工；1，派工")
    private Integer isDispatch;

    @ApiModelProperty("工作内容")
    @Length(max = 256, message = "计划内容不得超过256个字符")
    @NotBlank(message = "请输入计划内容")
    private String content;

    @ApiModelProperty("状态配置表")
    private Integer status;

    @ApiModelProperty("备注")
    @Length(max = 256, message = "备注不得超过256个字符")
    private String desc;

    @ApiModelProperty("计划所属部门")
    private String deptId;

    @ApiModelProperty("计划所属部门名称")
    private String deptName;

    @ApiModelProperty(value = "创建人账号")
    private String createBy;

    @ApiModelProperty(value = "创建人姓名")
    private String createByName;

    @ApiModelProperty(value = "创建时间")
    private List<Date> createTime;

    @ApiModelProperty(value = "更新人账号")
    private String updateBy;

    @ApiModelProperty(value = "更新人姓名")
    private String updateByName;

    @ApiModelProperty(value = "更新时间")
    private Date updateTime;

    @JsonIgnore
    @ApiModelProperty(value = "删除标志", hidden = true)
    private Boolean deleteFlag;

    @ApiModelProperty(value = "计划id")
    private String planId;

    @ApiModelProperty(value = "计划code")
    private String planCode;
}
